package edu.lingnan.lingnanblog.entity;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

/**
 * @author wenchang
 * @since 2020/6/17 22:44
 */
@Data
@NoArgsConstructor
@Accessors(chain = true)   // 开启链式写法
@ToString
@AllArgsConstructor
public class Comment {
    private Integer id; // 编号
    private String userIp; // 用户IP
    private String content; // 评论内容
    private Blog blog; // 被评论的博客
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date commentDate; // 评论日期
    private Integer state; // 审核状态  0 待审核 1 审核通过 2 审核未通过
}
